package com.maker997.ajax.entity;

import lombok.Data;

import java.util.ArrayList;
import java.util.List;

/**
 * 城市
 *
 * @author maker
 * @date 2017/11/13
 */
@Data
public class City {
    private long cid;
    private String name;

    public City(long cid, String name)
    {
        this.cid = cid;
        this.name = name;
    }

    public static List<City> listAllCity(long pid)
    {
        List<City> list = new ArrayList<City>();
        if (pid == 1)
        {
            City c0 = new City(1l,"济南");
            City c1 = new City(2l,"青岛");
            City c2 = new City(3l,"烟台");
            City c3 = new City(4l,"威海");
            City c4 = new City(5l,"日照");
            City c5 = new City(6l,"滨州");
            City c6 = new City(7l,"潍坊");
            City c7 = new City(8l,"莱芜");
            City c8 = new City(9l,"淄博");
            City c9 = new City(10l,"泰安");
            City c10 = new City(11l,"德州");
            City c11 = new City(12l,"菏泽");
            City c12 = new City(13l,"聊城");
            City c13 = new City(14l,"济宁");
            City c14 = new City(15l,"临沂");

            list.add(c0);
            list.add(c1);
            list.add(c2);
            list.add(c3);
            list.add(c4);
            list.add(c5);
            list.add(c6);
            list.add(c7);
            list.add(c8);
            list.add(c9);
            list.add(c10);
            list.add(c11);
            list.add(c12);
            list.add(c13);
            list.add(c14);

        }else if (pid == 2)
        {
            City c0 = new City(1l,"哈尔滨");
            City c1 = new City(2l,"绥化");
            City c2 = new City(3l,"佳木斯");
            City c3 = new City(4l,"齐齐哈尔");
            City c4 = new City(5l,"牡丹江");
            City c5 = new City(6l,"黑河");
            City c6 = new City(7l,"鸡西");

            list.add(c0);
            list.add(c1);
            list.add(c2);
            list.add(c3);
            list.add(c4);
            list.add(c5);
            list.add(c6);

        }else if (pid == 3)
        {
            City c0 = new City(1l,"石家庄");
            City c1 = new City(2l,"唐山");
            City c2 = new City(3l,"北戴河");
            City c3 = new City(4l,"霸州");
            City c4 = new City(5l,"邯郸");
            City c5 = new City(6l,"保定");
            City c6 = new City(7l,"沧州");

            list.add(c0);
            list.add(c1);
            list.add(c2);
            list.add(c3);
            list.add(c4);
            list.add(c5);
            list.add(c6);

        }
        return list;
    }
}
